(function(){
	jQuery.fn.showDialog = function(options) {
		if (!this.length) {
			log('Could not found the matched element!');
			return this;
		}
		var settings = {
		};
		function init(options)
		{
			$(this).find("#btn_about").click(function(e){
				e.preventDefault();
				alert(options['message']);
				var title = options['title'];
				var message = options['message'];
				var buttonLabel = '<input type="button" name="btnOK" value="OK" id="' + options['label_ok'] + '" onClick="FB.Dialog.remove(this);">';
				var content = '<div id="window_container"><div id="title_bar">' +title+ '</div><div id="message">' + message + '</div><div id="bottom_bar">' +buttonLabel+ '</div></div>';
				var dialog = FB.Dialog.create({
					content: content,
					closeIcon: true,
					onClose: function() {
						FB.Dialog.remove(dialog);
					},
					visible: true
				});
			});
		}

	}
	function log(obj) {
		if( window.console && console.log ) console.log(obj) ;
	}
})(jQuery);